const express = require('express')
const db =require('./db.js')
const bodyParser = require('body-parser');



//渲染主页面
exports.showIndex = (req,res)=>{
	let sql = 'select * from car';
	let message =[];
	db.base(sql,null,(results)=>{
		// console.log(results)
		// res.json(results)
		if(results){
			// console.log(results.type)
			res.json(results);
		}
	})
	
}